-- GENERATED SPELL FOR [Coilfang Soothsayer] --


function spell0_17960(pUnit, Event) --@Arcane Missiles,n/a--
pUnit:FullCastSpellOnTarget(15791,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_17960', 669, 1)
end

function spell1_17960(pUnit, Event) --@Decayed Intellect,n/a--
pUnit:FullCastSpellOnTarget(31555,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_17960', 20287, 1)
end

function Sorts_17960(pUnit, Event)
local choix_sorts_17960 = math.random(0, 1)
if choix_sorts_17960 == 0 then
pUnit:RegisterEvent('spell0_17960', 1, 1)
end
if choix_sorts_17960 == 1 then
pUnit:RegisterEvent('spell1_17960', 1, 1)
end
end

function mob17960_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_17960', math.random(1500, 3000), 1)
end

function mob17960_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob17960_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob17960_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(17960, 1, 'mob17960_Action')
RegisterUnitEvent(17960, 2, 'mob17960_Leave')
RegisterUnitEvent(17960, 3, 'mob17960_Kill')
RegisterUnitEvent(17960, 4, 'mob17960_Die')
